package com.dms.mapper;

import com.dms.pojo.Building;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;
import java.util.Map;

/**
 * @className: BuildingManageMapper
 * @package: com.dms.mapper
 * @description  楼宇管理模块Dao接口
 * @author: sk
 */
public interface BuildingManageMapper {
    //分页查询获取楼宇列表数据
    List<Building> getBuildingLimitList(Map<String,Object> map);

    //获取楼栋列表所有信息
    List<Building> getBuildingIdList();

    // 统计管理相同楼栋的管理员数
    int getTheSameManageBuildingCount(int buildingId);

    //获取楼栋列表total
    int getBuildingTotal(Map<String,Object> map);

    //判断楼栋号是否存在
    Building checkBuildingNumber(String buildingNumber);

    //添加新的楼栋
    int addBuilding(Building building);

    //根据 楼栋号查询楼栋信息
    Building getBuildingByNumber(String buildingNumber);

    //根据 楼栋号 修改楼栋信息
    int editBuildingByNumber(Building building);

    //删除楼栋信息
    int deleteBuilding(int buildingId);
}
